package rhc.taskSchedule.access.noticeCustom;

import org.apache.log4j.Logger;

import rhc.taskSchedule.taskSignalCall.CallCustom;

/**当任务分配到本节点时可以将该信号注册到平台，当平台接收到相应信号时会触发相应的事件
 * @author rhc
 *
 */
public class MyCallCustom implements CallCustom{

	private Logger logger=Logger.getLogger(getClass());
	
	/**
	 * 平台运行id，每一次运行生成的一个独有的id
	 */
	private String runningId;
	
	/**
	 * 客户系统注册到平台的id
	 */
	private String taskId;
	
	public MyCallCustom(String runningId,String taskId){
		this.runningId=runningId;
		this.taskId=taskId;
	}
	
	@Override
	public String getRunningId() throws Exception {
		return runningId;
	}

	@Override
	public String getTaskId() throws Exception {
		return taskId;
	}

	@Override
	public void run() throws Exception {
		logger.info("i run");
	}

	@Override
	public void stop() throws Exception {
		logger.info("i stop");
	}

	@Override
	public void pause() throws Exception {
		logger.info("i pause");
	}

	@Override
	public void regain() throws Exception {
		logger.info("i regain");
	}

}
